#pragma once

#ifdef USING_DIRECTX81
	// DirectX8 headers
	#include <d3d8.h>
	#include <d3dx8math.h>
	#include <d3dx8.h>
#else 
	// DirectX9 headers
	#include <d3d9.h>
	#include <d3dx9math.h>
#endif

#ifdef USING_DIRECTX81
	typedef LPDIRECT3DVERTEXBUFFER8		DX_LPVERTEXBUFFER;
	typedef D3DVIEWPORT8				DX_VIEWPORT;
	typedef D3DMATERIAL8				DX_MATERIAL;
	typedef LPDIRECT3DTEXTURE8			DX_LPTEXTURE;
	typedef LPDIRECT3DINDEXBUFFER8		DX_LPINDEXBUFFER;
	typedef LPDIRECT3DDEVICE8			DX_LPDIRECT3DDEVICE;
	typedef D3DLIGHT8					DX_LIGHT;
	typedef LPDIRECT3D8					DX_LPDIRECT3D;
	typedef D3DADAPTER_IDENTIFIER8		DX_ADAPTER_IDENTIFIER;
	typedef BYTE						DX_LOCK_3_PARAM;
#else 
	typedef LPDIRECT3DVERTEXBUFFER9		DX_LPVERTEXBUFFER;
	typedef D3DVIEWPORT9				DX_VIEWPORT;
	typedef D3DMATERIAL9				DX_MATERIAL;
	typedef LPDIRECT3DTEXTURE9			DX_LPTEXTURE;
	typedef LPDIRECT3DINDEXBUFFER9		DX_LPINDEXBUFFER;
	typedef LPDIRECT3DDEVICE9			DX_LPDIRECT3DDEVICE;
	typedef D3DLIGHT9					DX_LIGHT;
	typedef LPDIRECT3D9					DX_LPDIRECT3D;
	typedef D3DADAPTER_IDENTIFIER9		DX_ADAPTER_IDENTIFIER;
	typedef VOID						DX_LOCK_3_PARAM;
#endif
